####################################################
## Study military and education treatments ##
#need plotrix
####################################################
library("plotrix", lib.loc="F:/R/R-2.15.0/library")
x <- c(1.1, 1.25, 1.4, 1.55) #where the x axis points are
y <- c(.16, .854, .087, .885) #gen,~mil & mil treat, mil treat& mil, educ
se <- c(.126, .119, .126, .245)
#Fall miller + 
uiw <- 1.96*se
#porkc, military, military*pork interaction 
par(mar = c(1,4,1,2))
plotCI(x, y, uiw, ylim = c(-1.5, 2.3), xlim = c(1, 2.05), axes=F, family="serif",
  ylab=("Change in Support for Rep. Miller (FL-1st)"), family="serif",  main=(""), 
pch=c(0, 15, 0, 15)) 
	text(1.3, 2.25, "Rep. Miller Education & Military Treatments", family="serif",) 

#now the lower labels
	text(1.1, -.925, "General\nTreatment", cex=.8, family="serif",)
	text(1.25, -.925, "Education\nTreatment", cex=.8, family="serif",) #cex =font
	text(1.4, -.925, "Military \nTreatment,\nNo Military\nAffiliation", cex=.8, family="serif",)
	text(1.55, -.925, "Military \nTreatment,\nMilitary\nAffiliation", cex=.8, family="serif",)

	abline(h=0) # the control line
	#abline(v=.5)
	axis(side=2) #where the y axis is
text( 1.05, -1.4, adj=0, family="serif","Note: estimates represent the marginal treatment effect on support for the 
indicated Member with 95% confidence intervals. Solid symbols are statistically 
significant at the p<0.05 level, two-tailed. Rep. Miller Treatment N=438.", 
cex=.7)
#segments(1.25, -.8, 1.25, 2, lty=3) #this is the bisection line
#segments(1.55, -.8, 1.55, 2, lty=3) #this is the bisection line

#,  adj=c(-.2,1)